]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
authPrompt: stop spinner after its hidden
authorRay Strode <rstrode@redhat.com>
Fri, 21 Aug 2015 13:09:39 +0000 (09:09 -0400)
committerRay Strode <rstrode@redhat.com>
Mon, 31 Aug 2015 19:19:26 +0000 (15:19 -0400)
The code previously tried to stop spinner after it was hidden, but
due to an incorrect check was only stoppig it after it was shown.

Also, it was only stopping after hiding due to an animation, and
failing to stop it in the non-animated case.

This left the spinner hidden and running while VT switched away
from the login screen, only stopping when the auth prompt was
reset when switching back.

https://bugzilla.gnome.org/show_bug.cgi?id=753891

data/theme/gnome-shell-sass
js/gdm/authPrompt.js

index 034d0b775b12f2212ba2028b153e4c2f31e6fa65..172666394146a88445811e86ce37a3f36775004c 160000 (submodule)
@@ -1 +1 @@
-Subproject commit 034d0b775b12f2212ba2028b153e4c2f31e6fa65
+Subproject commit 172666394146a88445811e86ce37a3f36775004c
index c30789e2048b92769552830f14ee4b84283bd2e1..465cb3dfc4445f607e22f145028f62d20da60343 100644 (file)
@@ -281,6 +281,12 @@ const AuthPrompt = new Lang.Class({
         if (oldActor)
             Tweener.removeTweens(oldActor);
 
+        let wasSpinner;
+        if (oldActor == this._spinner.actor)
+            wasSpinner = true;
+        else
+            wasSpinner = false;
+
         let isSpinner;
         if (actor == this._spinner.actor)
             isSpinner = true;
@@ -290,6 +296,11 @@ const AuthPrompt = new Lang.Class({
         if (this._defaultButtonWellActor != actor && oldActor) {
             if (!animate) {
                 oldActor.opacity = 0;
+
+                if (wasSpinner) {
+                    if (this._spinner)
+                        this._spinner.stop();
+                }
             } else {
                 Tweener.addTween(oldActor,
                                  { opacity: 0,
@@ -298,7 +309,7 @@ const AuthPrompt = new Lang.Class({
                                    transition: 'linear',
                                    onCompleteScope: this,
                                    onComplete: function() {
-                                      if (isSpinner) {
+                                      if (wasSpinner) {
                                           if (this._spinner)
                                               this._spinner.stop();
                                       }